/*
wordslist.h
(c) 2010 Yury Hamenkov
This file is part of qWordCards.

qWordCards is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

qWordCards is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with qWordCards. If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef WORDSLIST_H
#define WORDSLIST_H

#include <QObject>
#include <QSet>

namespace qWordCards {
	class WordsList : public QObject {
		Q_OBJECT
		private:
			QSet<QString> _words;
			
		public:
			explicit WordsList(QObject *parent = 0);
			void AddWord(QString word);
			void RemoveWord(QString word);
			bool Contains(QString word) const;
			void Substract(const WordsList&);
			
			void Save(QString fileName);
			void Load(QString fileName);
		
		signals:
			void sg_WordAdded(QString);
			void sg_WordRemoved(QString);
		
		public slots:
	
	};
}

#endif // WORDSLIST_H
